import { Module } from '@nestjs/common';
import { AuthService } from './auth.service';
import { UsersModule } from '@src/modules/users/users.module';
import { PassportModule } from '@nestjs/passport';
import { LocalStrategy } from './local.strategy';
import { JwtStrategy } from './jwt.strategy';
import { JwtModule } from '@nestjs/jwt';
import { config } from '@src/config/index';


@Module({

   imports: [
      UsersModule,
      PassportModule,
      JwtModule.register({
         secret: config.jwt.secretOrKey,
         signOptions: config.jwt.signOptions,
      })
   ],
   providers: [AuthService, LocalStrategy, JwtStrategy],
   exports: [AuthService],
})
export class AuthModule { }
